/**
 * @Date: Feb 26, 2010 1:32:09 PM
 */
package com.philip.journal.core.dao;

import com.philip.journal.core.bean.User;

/**
 * @author cry30
 */
public interface UserDAO {

    /**
     * Retrieves a User object by username.
     *
     * @param username
     *            case sensitive username to read from data source.
     * @return return the User object having the specified username. null when no object match is found.
     */
    User readByUsername(String username);

    /**
     * Persist a User state into the database.
     *
     * @param user
     *            user entity to persist.
     */
    void save(User user);

}
